package com.fenqiyong.www.di;


import com.fenqiyong.www.ACodeAct;
import com.fenqiyong.www.ALoginAct;
import com.fenqiyong.www.AUploadAct;
import com.fenqiyong.www.LockAct;
import com.fenqiyong.www.MainAct;
import com.fenqiyong.www.SplashAct;
import com.fenqiyong.www.WebActivity;
import com.fenqiyong.www.fragment.Statea;
import com.fenqiyong.www.fragment.Stated;
import com.fenqiyong.www.fragment.Statec;

import com.fenqiyong.www.mvp.IndexModule;
import com.fenqiyong.www.mvp.MineModule;
import com.fenqiyong.www.fragment.Stateb;
import com.fenqiyong.www.mvp.NewCarModule;
import com.fenqiyong.www.mvp.SecondNewCarModule;

import dagger.Module;
import dagger.android.ContributesAndroidInjector;
import ren.nearby.http.di.BaseActivityComponent;
import ren.nearby.http.di.BaseFragmentV4Component;
import ren.nearby.http.scope.ActivityScoped;


/**
 * 配置所有activity注入
 * Created by Administrator on 2018/5/3 0003.
 */


@Module(subcomponents = {
        // 注入 activity
        BaseActivityComponent.class,
        //android.app.Fragment 兼容的最低版本是android:minSdkVersion="11" 即3.0版
//        BaseFragmentComponent.class,
        //android.support.v4.app.Fragment 兼容的最低版本是android:minSdkVersion="4" 即1.6版
        BaseFragmentV4Component.class
})
public abstract class AllActivitysModule {

    //------------------主入口模块--------------------
    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract SplashAct splashAct();

    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract MainAct mainAct();

    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract Statea a();

    @ActivityScoped
    @ContributesAndroidInjector(modules = NewCarModule.class)
    abstract Statec b();


    @ActivityScoped
    @ContributesAndroidInjector(modules = SecondNewCarModule.class)
    abstract Stateb c();

    @ActivityScoped
    @ContributesAndroidInjector(modules = MineModule.class)
    abstract Stated d();

    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract LockAct lockAct();

    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract WebActivity webActivity();

    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract ALoginAct aLoginAct();

    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract ACodeAct aCodeAct();


    @ActivityScoped
    @ContributesAndroidInjector(modules = IndexModule.class)
    abstract AUploadAct aUploadAct();


    //------------------end-----------------------


}
